package com.edu.service;

import java.util.List;

import com.edu.entity.Articles;
import com.edu.util.PageData;
import com.edu.entity.Types;

public interface IArticleService {
	    //æ ¹æ®æç« æ é¢æ¨¡ç³æ¥è¯¢
		public List<Articles> queryArticlesByLike(String articleLike);
		
		//æ ¹æ®æç« æ é¢æ¨¡ç³æ¥è¯¢
		public List<Articles> queryArticlesById(String articlesId);
		
		//æ¥è¯¢æ¶é´ååå3æç« 
		public List<Articles> queryTopArticles();
		//æ¥è¯¢ææè¯¾ç¨
		public List<Articles> getAllArticles();
		//æ³¨éè¯¾ç¨
		public boolean outArticle(int articleId) ;
		//æ¢å¤è¯¾ç¨
		public boolean inArticle(int articleId) ;
		//åé¡µæ¾ç¤ºæææåçº¿æ¥è¯¢
		public PageData getAllArticlesByTitle(int pageNo,int pageSize,String titleKey);
		//æ¥è¯¢å½æ¥æç« åæ æ°
		public int getNewArticlecount();
		//æ¥è¯¢å½æ¥æç« åæ æ°
		public int getAllArticlecount();
		
		//æ¥çææè¯¾ç¨ä¿¡æ¯
		public List<Articles> queryArticles();

		//æ·»å æç« 
		boolean insertArticle(Articles articles);
		//è·åç±»åç¼å·
		Types getTypeId(String typeContent);
		
		//æ¥è¯¢7å¤©æ°å¢é
		public int[] get7DayArticles();
		//根据Id查找文章
		public Articles queryArticlesById(int atricleId);
        //查询每个类型的文章数量
		public int[] getTypeArticles();
		
		//查询类型名
		public List<String> getTypeName();
		//根据类型查询分页
		public PageData getAllArticlesByTypes(int pageNo, int pageSize, String typesname,String keytitle);
		
		//获得心灵鸡汤
		public String getGoodWord();
		
		//增加阅读量
		public boolean addRead(int articleId);
	
}
